<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>todo</title>
</head>
<body>
    <h1>TODO</h1>
    <form action="/todo/add" method="post">
        <input name="task">
        <button>add todo</button>
    </form>
    <!--    <div>{{todos}}</div>-->
    {% for t in todos %}
        <div>
            {{ t.id }} : {{ t.task }} @ {{ t.ct() }}
            <a href="/todo/edit?id={{t.id}}">edit</a>
            <a href="/todo/delete?id={{t.id}}">删除</a>
        </div>
    {% endfor %}
</body>
</html>